home *** CD-ROM | disk | FTP | other *** search
/ Alles Voor Internet / Tout Pour Internet / alles voor internet.iso / MacInternet™ / Telnet / NCSA / tn3270 2.4d7 source / NCSA⁄BYU TCP⁄IP / whatami.h < prev   
Text File  |  1991-08-06  |  3KB  |  140 lines

  1. /*
  2. *    Whatami.h
  3. *  Machine specific information for NCSA Telnet TCP/IP kernel
  4. ****************************************************************************
  5. *                                                                          *
  6. *                                                                          *
  7. *      NCSA Telnet                                                         *
  8. *      by Tim Krauskopf, VT100 by Gaige Paulsen, Tek by Aaron Contorer     *
  9. *                                                                          *
  10. *      National Center for Supercomputing Applications                     *
  11. *      152 Computing Applications Building                                 *
  12. *      605 E. Springfield Ave.                                             *
  13. *      Champaign, IL  61820                                                *
  14. *                                                                          *
  15. *    Copyright (c) 1987, Board of Trustees of the University of Illinois   *
  16. *                                                                          *
  17. ****************************************************************************
  18. *   Defines for TCP/IP library, are you a Mac or a PC?
  19. */
  20.  
  21. #ifndef MAC
  22. #define PC 1
  23. #define ETHER 1
  24. #define UB 1 
  25. #endif
  26.  
  27. #define ETHER
  28.  
  29. #ifndef ETHER
  30. #define ATALK 1
  31. #endif
  32.  
  33. /*
  34. *   Defines which have to do with Ethernet addressing versus Appletalk
  35. *   addressing.  Ethernet has 6 bytes of hardware address, ATALK has 4
  36. */
  37. #ifdef ETHER
  38. #define DADDLEN 6
  39. #define WINDOWSIZE 4096
  40. #define TSENDSIZE 512
  41. #define DEFWINDOW 1024
  42. #define DEFSEG    1024
  43. #define TMAXSIZE 1024
  44. #define UMAXLEN 1024
  45. #define ICMPMAX 300 
  46. #else
  47. /*  define for AppleTalk */
  48. #define DADDLEN 4
  49. #define WINDOWSIZE 4096
  50. #define TSENDSIZE 512
  51. #define DEFWINDOW 512
  52. #define DEFSEG    512
  53. #define TMAXSIZE 512
  54. #define UMAXLEN 512
  55. #define ICMPMAX 300 
  56. #endif
  57.  
  58.  
  59. #ifdef PC
  60. /*
  61. *  define length of an integer
  62. */
  63. typedef char int8;
  64. typedef unsigned char uint8;
  65. typedef int int16;
  66. typedef long int int32;
  67. typedef unsigned int uint16;
  68. typedef unsigned long int uint32;
  69.  
  70.  
  71. #define TICKSPERSEC 18
  72. #define SMINRTO 5
  73. #define WRAPTIME 86400L                /* in seconds, only for PC */
  74. #define NPORTS    30
  75. #define CONNWAITTIME 20                /* default contime in seconds */
  76. uint32 longswap();
  77.  
  78. #else
  79. /*
  80. *  define length of an integer
  81. */
  82.  
  83. #define NFDEF {0,0,0}
  84. #define NBDEF {65535,65535,65535}
  85. #define BFDEF {0,61183,11060}
  86. #define BBDEF {61183,2079,4938}
  87. #define UFDEF {1,0,0}
  88. #define UBDEF {0,0,0}
  89.  
  90. typedef char int8;
  91. typedef unsigned char uint8;
  92.  
  93. #ifdef MPW
  94. typedef short int int16;
  95. typedef long int int32;
  96. typedef unsigned int uint;
  97. typedef unsigned short int uint16;
  98. typedef unsigned long int uint32;
  99. #define ctop(x) x
  100. #define ptoc(x) x
  101. #define index(x,y) strchr(x,y)
  102.  
  103. #define malloc(A) NewPtr(A)
  104. #define free(A) DisposPtr(A)
  105.  
  106. #else
  107. typedef int int16;
  108. typedef unsigned int uint;
  109. typedef long int int32;
  110. typedef unsigned int uint16;
  111. typedef unsigned long int uint32;
  112. #endif
  113.  
  114. #define TICKSPERSEC 60
  115. #define SMINRTO 25
  116. #define NPORTS    30
  117. #define CONNWAITTIME 20                /* default contime in seconds */
  118.  
  119. #define    longswap(x) x
  120. #define intswap(x) x
  121. #ifndef MPW
  122. #define movebytes(x,y,z) movmem(y,x,z)
  123. #define movenbytes(x,y,z) movmem(y,x,z)
  124. #else
  125. #define movebytes(x,y,z) memcpy(x,y,z)
  126. #define movenbytes(x,y,z) memcpy(x,y,z)
  127. #endif 
  128. #define n_putchar(x) putchar(x)
  129. #define n_puts(x) putln(x)
  130. #define NPORTS    30
  131.  
  132. #ifdef MPW
  133. #define FALSE false
  134. #define TRUE true
  135. #endif MPW
  136. #endif
  137.  
  138. #include "netevent.h"
  139.  
  140.